<meta charset="UTF-8">
<style>
th{
	text-align:center
}
td{
	text-align:center
}
</style>
<div class="content-wrapper" style="min-height: 901px;">
    <!-- Content Header (Page header) -->
    <section class="content-header">
      <h1 style="text-align:center">
        	发卡退卡
      </h1>
    </section>

    <!-- Main content -->
    <section class="content">
      <div class="row">
        <div class="col-md-12">
          <div class="box">
          <div class="box-header">
          	<div class="col-md-2 btn-group">
			 	<select class="btn btn-default" style="width: 100%;" ng-model="searchSendBackobj.query_terms">
			 		<option value="按明细">按明细</option>
			 		<option value="按汇总">按汇总</option>
			 	</select>
			 </div>
			 <div class='col-md-4'>
			 	<input type="text" class="form-control pull-right" id="reservation" ng-model="dateStr">
			 </div>
             <button class="btn btn-default" ng-click="searchSendBack();">查询</button>
          	 <button class="btn pull-right" ng-click="downloadSendBack(searchSendBackobj.query_terms)"><i class="fa fa-cloud-download"></i>&nbsp;&nbsp;导出</button>
          </div>
            <div class="box-body table-responsive no-padding">
              <table class="table table-hover">
                 <tbody ng-show="!details">
                <tr>
                  <td>发卡人</td>
                  <td>发卡数量</td>
                  <td>退卡数量</td>
                 </tr>
                <tr ng-repeat="d in items">
                	<td>{{d.operator}}</td>
                	<td>{{d.open_num}}</td>
                	<td>{{d.back_num}}</td>
                </tr>
               </tbody>
                
                <tbody ng-show="details">
                
                <tr >
                  <td>卡号</td>
                  <td>卡类型</td>
                  <td>业务类型</td>
                  <td>用户姓名</td>
                  <td>操作人</td>
                  <td>操作时间</td>
                 </tr>
                <tr ng-repeat="dt in items">
                	<td>{{dt.card_id}}</td>
                	<td>{{dt.card_type}}</td>
                	<td>{{dt.service_type}}</td>
                	<td>{{dt.username}}</th>
                	<td>{{dt.operator}}</td>
                	<td>{{dt.time}}</td>
                </tr>
               </tbody>
            </table>
           <!-- //用于导出的表格-->
            <table class="table table-hover download" id="tb_sendbackByNum" >
                 <tbody>
                <tr>
                  <td>发卡人</td>
                  <td>发卡数量</td>
                  <td>退卡数量</td>
                 </tr>
                <tr ng-repeat="d in callBackData[0].summary">
                	<td>{{d.operator}}</td>
                	<td>{{d.open_num}}</td>
                	<td>{{d.back_num}}</td>
                </tr>
               </tbody>
            </table>  
             <table class="table table-hover download" id="tb_sendbackByDetails" >
                <tbody>
                
                <tr >
                  <td>卡号</td>
                  <td>卡类型</td>
                  <td>业务类型</td>
                  <td>用户姓名</td>
                  <td>操作人</td>
                  <td>操作时间</td>
                 </tr>
                <tr ng-repeat="dt in callBackData[0].details">
                	<td>{{dt.card_id}}</td>
                	<td>{{dt.card_type}}</td>
                	<td>{{dt.service_type}}</td>
                	<td>{{dt.username}}</th>
                	<td>{{dt.operator}}</td>
                	<td>{{dt.time}}</td>
                </tr>
               </tbody>
            </table>
			</div>
            <!-- /.box-body -->
           <div class="box-footer" style="margin-bottom:10px;">
	              	
	              		<div class="dataTables_info col-sm-2" id="example1_info" role="status" aria-live="polite">总条目数：{{totalNums}}</div>
	              	
	               
	                	
	                		<label class="col-md-2" style="font-weight:normal;float:left;padding-right:15px;">每页显示数目 
	                			
	                		</label>
	                		<div class="col-md-2">
	                			
	                		
	                		<select name="example1_length" aria-controls="example1" class="form-control input-sm" ng-change="change(initial)" ng-model="initial" > 
	                				<option value="10">10</option> 
	                				<option value="25">25</option>
	                				<option value="50">50</option>
	                				<option value="100">100</option>
	                		    </select>
	                		</div>
	                		<div class="col-md-6">
	                			<ul class="pagination pull-right" style="margin: 0px;">
		                			<li class="paginate_button previous" id="example1_previous">
		                				<a  ng-click="Previous()">上一页</a>
		                			</li>
		                			<li   ng-repeat="page in pageList" ng-class="{active: isActivePage(page)}"><!-- class=" paginate_button active" -->
		                				<a  ng-click="selectPage(page)">{{page}}</a>
		                			</li>
		                			<li class="paginate_button next" id="example1_next">
		                				<a  ng-click="Next()">下一页</a>
		                			</li>
	                			</ul>
	                		</div>
	                		
	                	
	                
	              </div>
          </div>
          <!-- /.box -->
        </div>
      </div>
    </section>
    <!-- /.content -->
  </div>
